from api.global_conf import DBCONF, LOGPATH
from api.user import login
from utils.index import DBhelper, Logs


class BaseCasewithLogin:
    def setup_class(self):
        self.db = DBhelper(**DBCONF)
        self.log = Logs(LOGPATH)
        login_res = login({
            "username": "zhangfeidameinv",
            "password": "123"
        })
        self.cookie = login_res.headers['Set-Cookie']

